//
//  UIButton+ExXibFont.m
//  IdealerClub
//
//  Created by 王芳 on 16/2/28.
//  Copyright © 2016年 IC. All rights reserved.
//

#import "UIButton+ExXibFont.h"

@implementation UIButton (ExXibFont)
+ (void)load{
    Method imp = class_getInstanceMethod([self class], @selector(initWithCoder:));
    Method myImp = class_getInstanceMethod([self class], @selector(myInitWithCoder:));
    method_exchangeImplementations(imp, myImp);
}

- (instancetype)myInitWithCoder:(NSCoder *)aDecode{
    [self myInitWithCoder:aDecode];
    if (self) {
        CGFloat fontSize = self.titleLabel.font.pointSize;
        self.titleLabel.font = [UIFont fontWithName:@"Tensentype-JiaLiXiYuanJ" size:fontSize];
    }
    return self;
}
@end
